<?php
/**
 * Template Name:create_index
 * 
 */
$smarty = smarty_get_instance();

//首页幻灯片内容生成
$huandeng = nocat_quaricle(104,8);

//热图Hot 上数第二行
$hotimg = nocat_quaricle(105,3);

//第一行第二列精彩推荐上半部分
$jingcai_top = nocat_quaricle(106,4);

//第一行第二列精彩推荐下半部分
$jingcai_bottom = nocat_quaricle(107,10);

//第一行第三列最新文章
$new_article = nocat_quaricle(108,1);

//第三四行第二列 点击排行榜
$paihanglist = paihanglist(109,"link1",null,3);

//第三行第一列 右侧下部分左边5条数据
$third_first_left= catid_article(110,6,1);

//第三行第一列 右侧下部分右边边5条数据
$third_first_right = catid_article(110,6,3);

//第四行第一列 右侧下部分左边5条数据
$forth_first_left= catid_article(110,5,1);

//第四行第一列 右侧下部分右边边5条数据
$forth_first_right = catid_article(110,5,3);

//第五行第一列 右侧下部分左边5条数据
$five_first_left= catid_article(110,3,1);

//第五行第一列 右侧下部分右边边5条数据
$five_first_right = catid_article(110,3,3);

//第六行上半部分
$six_first_left= catid_article(111,4,1);

//第六行下半部分
$six_first_right = catid_article(112,4,3);

//第三行右侧上部分
$third_right_top = catid_article(113,6,5);

//第四行右侧上部分
$forth_right_top = catid_article(113,5,5);

//第五行右侧上部分
$five_right_top = catid_article(114,3,5);

//第三行左侧
$third_left = catid_article(115,6,8);

//第四行左侧
$forth_left = catid_article(115,5,8);

//第五行左侧
$five_left = catid_article(116,5,8);

$smarty->assign ( "huandeng",$huandeng);
$smarty->assign ( "hotimg",$hotimg);
$smarty->assign ( "jingcai_top",$jingcai_top);
$smarty->assign ( "jingcai_bottom",$jingcai_bottom);
$smarty->assign ( "new_article",$new_article);
$smarty->assign ( "paihanglist",$paihanglist);
$smarty->assign ( "third_first_left",$third_first_left);
$smarty->assign ( "third_first_right",$third_first_right);
$smarty->assign ( "forth_first_left",$forth_first_left);
$smarty->assign ( "forth_first_right",$forth_first_right);
$smarty->assign ( "five_first_left",$five_first_left);
$smarty->assign ( "five_first_right",$five_first_right);
$smarty->assign ( "six_first_left",$six_first_left);
$smarty->assign ( "six_first_right",$six_first_right);
$smarty->assign ( "third_right_top",$third_right_top);
$smarty->assign ( "forth_right_top",$forth_right_top);
$smarty->assign ( "five_right_top",$five_right_top);
$smarty->assign ( "third_left",$third_left);
$smarty->assign ( "forth_left",$forth_left);
$smarty->assign ( "five_left",$five_left);


$content = $smarty->fetch("index.tpl");
$fp = fopen( "/home/admin/tueye/wordpress/wp-content/themes/tueye/index.html", "w" );
fwrite($fp,$content);
fclose($fp);
?>